<!DOCTYPE html>
<html lang="zh-CN">
<head>
  <meta charset="UTF-8">
  <meta name="author" content="wangbo">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <!-- 内部样式 -->
  <style>
    /* 行内元素,没有宽高,浮动可以使元素具有行内块的特点
    既有宽高,又可以在一行内显示
     */
    span{
      width: 200px;
      height: 200px;
      float: left;
    }
    .c1{background-color: chartreuse; 
    }
    .c2{
      background-color:red;
    }
  </style>
</head>
<body>
  <span class="c1">我是div1</span>
  <span class="c2">我是div2</span>
</body>
</html>